<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>HTTP Request 变量</title>

 </head>
 <body><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="reserved.variables.files.html">$_FILES</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="reserved.variables.session.html">$_SESSION</a></div>
 <div class="up"><a href="reserved.variables.html">预定义变量</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div><hr /><div id="reserved.variables.request" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">$_REQUEST</h1>
  <p class="refpurpose"><span class="refname">$_REQUEST</span> &mdash; <span class="dc-title">HTTP Request 变量</span></p>

 </div>
 
 <div class="refsect1 description" id="refsect1-reserved.variables.request-description">
  <h3 class="title">说明</h3>
  <p class="para">
   默认情况下包含了 <var class="varname"><var class="varname"><a href="reserved.variables.get.html" class="classname">$_GET</a></var></var>，<var class="varname"><var class="varname"><a href="reserved.variables.post.html" class="classname">$_POST</a></var></var>  和  <var class="varname"><var class="varname"><a href="reserved.variables.cookies.html" class="classname">$_COOKIE</a></var></var> 的<span class="type"><span class="type 数组">数组</span></span>。
  </p>
 </div>

 

 <div class="refsect1 changelog" id="refsect1-reserved.variables.request-changelog">
  <h3 class="title">更新日志</h3>
  <p class="para">
   <table class="doctable informaltable">
    
     <thead>
      <tr>
       <th>版本</th>
       <th>说明</th>
      </tr>

     </thead>

     <tbody class="tbody">
      <tr>
       <td>5.3.0</td>
       <td>
        引入 <a href="ini.core.html#ini.request-order" class="link">request_order</a>。该指令会影响 <var class="varname"><var class="varname">$_REQUEST</var></var> 的内容。
       </td>
      </tr>

      <tr>
       <td>4.3.0</td>
       <td>
        <var class="varname"><var class="varname"><a href="reserved.variables.files.html" class="classname">$_FILES</a></var></var> 信息被从 <var class="varname"><var class="varname">$_REQUEST</var></var> 中移除。
       </td>
      </tr>

      <tr>
       <td>4.1.0</td>
       <td>
        引入 <var class="varname"><var class="varname">$_REQUEST</var></var>。
       </td>
      </tr>

     </tbody>
    
   </table>

  </p>
 </div>

 
 <div class="refsect1 notes" id="refsect1-reserved.variables.request-notes">
  <h3 class="title">注释</h3>
  <blockquote class="note"><p><strong class="note">Note</strong>: <p class="para">“Superglobal”也称为自动化的全局变量。这就表示其在脚本的所有作用域中都是可用的。不需要在函数或方法中用
<strong class="command">global $variable;</strong> 来访问它。</p></p></blockquote>
  <blockquote class="note"><p><strong class="note">Note</strong>: 
   <p class="para">
    以<a href="features.commandline.html" class="link">命令行</a>方式运行时，将<em class="emphasis">不</em>包含 <a href="reserved.variables.argv.html" class="link">argv</a> 和 <a href="reserved.variables.argc.html" class="link">argc</a> 信息；它们将存在于 <var class="varname"><var class="varname"><a href="reserved.variables.server.html" class="classname">$_SERVER</a></var></var> <span class="type"><span class="type 数组">数组</span></span>。
   </p>
  </p></blockquote>
  <blockquote class="note"><p><strong class="note">Note</strong>: 
   <p class="para">
    由于 <var class="varname"><var class="varname">$_REQUEST</var></var> 中的变量通过 GET，POST 和 COOKIE 输入机制传递给脚本文件，因此可以被远程用户篡改而并不可信。这个数组的项目及其顺序依赖于 PHP 的 <a href="ini.core.html#ini.variables-order" class="link">variables_order</a> 指令的配置。
   </p>
  </p></blockquote>
 </div>


 <div class="refsect1 seealso" id="refsect1-reserved.variables.request-seealso">
  <h3 class="title">参见</h3>
  <ul class="simplelist">
   <li class="member"><span class="function"><a href="function.import-request-variables.html" class="function" rel="rdfs-seeAlso">import_request_variables()</a> - 将 GET／POST／Cookie 变量导入到全局作用域中</span></li>
   <li class="member"><a href="language.variables.external.html" class="link">处理外部变量</a></li>
   <li class="member"><a href="book.filter.html" class="link">过滤器扩展</a></li>
  </ul>
 </div>

 
</div><hr /><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="reserved.variables.files.html">$_FILES</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="reserved.variables.session.html">$_SESSION</a></div>
 <div class="up"><a href="reserved.variables.html">预定义变量</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div></body></html>
